<template>
  <div>
    home
  </div>
  <button @click="handleClick">{{count}}</button>
</template>

<script lang="ts">
//不能使用2.x语法
 export default{
   data(){
     return{
       count:1
     }
   },
   methods:{
     handleClick(){
       console.log(this)
     }
   }
 }
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 60px;
}
</style>
